home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Brotikasten
/
BROTCD01.iso
/
lern
/
lern451.d64
/
sound helper
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
1995-08-09
|
7KB
|
220 lines
1 REM MICAH KORNBERG MAY 6,1983
4 REM ************************************************************************
5 REM ******* SCREEN LOCATION ************************************************
6 :SC=1024
10 REM **** SID LOCATION ******************************************************
12 :SID=54272
15 REM **** DIM ARRAY A AND S *************************************************
19 :DIM D(25),A(25)
20 REM **** READ ARRAY A (SCREEN LOCATION)************************************
25 :FOR I=0 TO 24:READ A(I):A(I)=A(I)+SC:NEXT I
30 REM **** SCREEN,BORDER AND CHARACTER COLOUR*********************************
35 :PRINT"[144]":POKE 53280,15:POKE 53281,15
40 REM **** SET DURATION OF SOUND *********************************************
45 :DU=255
50 REM **** PRINT INSTRUCTIONS ************************************************
55 :GOSUB 6000
60 REM **** SETUP SCREEN DISPLAY **********************************************
65 :GOSUB 100:GOSUB 1350:GOTO 2000
70 REM ************************************************************************
100 REM *** SCREEN SETUP ******************************************************
105 PRINT"[147]";
110 PRINT" VOICE (1) (2) (3)
130 [153]"FREQUENCY
140 PRINT" (L)------------ A[146] H[146] O[146]
145 [153]""
160 [153]" (H)------------ BWAIT IWAIT PWAIT
165 PRINT""
170 PRINT"VARIABLE PULSE
180 [153]" (L)------------ CWAIT JWAIT QWAIT
185 PRINT""
200 PRINT" (H)------------ D[146] K[146] R[146]
205 [153]""
210 [153]"CONTROL REGISTER-- EWAIT LWAIT SWAIT
220 PRINT"
230 [153]"ATTACK/DECAY------ FWAIT MWAIT TWAIT
240 PRINT"
250 [153]"SUSTAIN/RELEASE--- GWAIT NWAIT UWAIT
260 PRINT"[192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192]";
270 PRINT"FILTER FREQUENCY (L) V[146] (H) W[146]
280 [153]"
290 PRINT"RESONANCE/FILTER VOICES X[146]
300 [153]"
310 PRINT"PASSBAND/MASTER VOLUME Y[146]
315 [142]
1000 [143] ** ROUTINE TO POKE TO SCREEN AND MEMORY ******************************
1030 N$[178][201]([196](D(N)),[195]([196](D(N)))[171]1)
1035 [129] I[178]0 [164] 2:[151] A(N)[170]I,32:[130] I
1040 [129] I[178]0 [164] [195](N$)[171]1
1050 [151] A(N)[170]I,[197]([202](N$,I[170]1,1))[170]48:[151] 54272[170]A(N)[170]I,0
1060 [130] I
1070 [151] SID[170]N,D(N)
1080 [142]
1100 [143] ** ROUTINE FOR VOICE 1,2, OR 3 ***************************************
1105 [139] D(N)[178]255 [167] D(N)[178]254
1110 D(N)[178]D(N)[170]1
1120 [151] SID[170]N,D(N)
1130 [129] I[178]1 [164] DU:[130] I
1140 D(N)[178]D(N)[171]1
1150 [151] SID[170]N,D(N)
1160 [142]
1200 [143] ** ROUTINE FOR VOICE 1,2AND 3 ****************************************
1205 [139] D(4)[178]255 [167] D(4)[178]254
1206 [139] D(11)[178]255 [167] D(11)[178]254
1207 [139] D(18)[178]255 [167] D(18)[178]254
1210 [151] SID[170]4,D(4)[170]1
1220 [151] SID[170]11,D(11)[170]1
1230 [151] SID[170]18,D(18)[170]1
1240 [129] I[178]1[164]DU:[130]I
1250 [151] SID[170]4,D(4)
1260 [151] SID[170]11,D(11)
1270 [151] SID[170]18,D(18)
1280 [142]
1300 [143] ** ROUTINE TO RESTART ************************************************
1310 [141] 1550
1320 [153]"PRESS YWAIT TO RESTART";
1330 [161]A$:[139]A$[178]""[167] 1330
1332 [141] 1550
1336 [153]" ";
1340 [139]A$[179][177]"Y"[167] 2000
1350 [129]N[178]0[164]24
1360 [151] SID[170]N,0
1370 D(N)[178]0
1380 [129] I[178]0 [164] 2:[151] A(N)[170]I,32:[151] 54272[170]A(N)[170]I,0:[130] I
1390 [151] A(N),48
1393 [130] N
1395 [142]
1400 [143] ** ROUTINE TO QUIT ***************************************************
1410 [141] 1550
1420 [153]"PRESS YWAIT TO QUIT ";
1430 [161] A$:[139] A$[178]"" [167] [137] 1430
1435 [141] 1550
1437 [153]" ";
1440 [139] A$[179][177]"Y" [167] 2000
1450 [153]"LOAD":[128]
1500 [143] ** ROUTINE TO GOTO LINE 23 *******************************************
1510 [153]"";
1520 [153]" ";
1530 [153]"";
1540 [142]
1550 [143] ** ROUTINE TO GOTO LINE 24 *******************************************
1560 [153]"";
1570 [153]" ";
1580 [153]"";
1590 [142]
2000 [143] ** MAIN INPUT ROUTINE ************************************************
2010 [141] 1500:[141] 1550
2020 [153]"ENTER COMMAND C:R:Q:I:F1:F3:F5:F7 ";
2030 [161] A$:[139] A$[178]"" [167] 2030
2040 [139] A$[178]"C" [167] [141] 3000
2050 [139] A$[178]"R" [167] [141] 1300
2060 [139] A$[178]"Q" [167] [141] 1400
2065 [139] A$[178]"I" [167] [141] 7000
2070 [139] A$[178]"INPUT" [167] N[178]4:[141] 1100
2080 [139] A$[178]"DIM" [167] N[178]11:[141] 1100
2090 [139] A$[178]"READ" [167] N[178]18:[141] 1100
2100 [139] A$[178]"LET" [167] [141] 1200
2110 [137] 2000
3000 [143] ** ROUTINE TO CHANGE VALUES ******************************************
3010 [141] 1550
3020 [153]"FOR WHICH LOCATION (A-Y) ";
3030 [161] N$:[139] N$[178]"" [167] 3030
3035 [139] [198](N$)[179]65 [176] [198](N$)[177]89 [167] [137] 3030
3040 N[178][198](N$)[171]65
3050 [141] 1550
3060 [153]"CHANGE ";N$;"WAIT TO (0-255) ";
3070 [141] 1500
3080 [141] 8000
3090 [139] D(N)[179]0 [176] D(N)[177]255 [167] [137] 3070
3100 [141] 1000
3110 [142]
5000 [131] 101,181,301,381,461,541,621
5010 [131] 108,188,308,388,468,548,628
5020 [131] 115,195,315,395,475,555,635
5030 [131] 706,716,786,866,0,0,0,0,0,0
6000 [143] ** INSTRUCTIONS ON HOW TO USE ****************************************
6010 [153]"LOAD";
6020 [153]" SOUND HELPER "
6030 [153]""
6040 [153]" BY MICAH KORNBERG"
6050 [129] I[178]1 [164] 2000:[130] I
6060 [153]"LOADINSTRUCTIONS FOR SOUND HELPER CLOSE WAIT";
6080 [153]" THIS IS A VERY SIMPLE PROGRAM, THEREARE ONLY A FEW";
6090 [153]" THINGS YOU HAVE TO KNOW TO BE ABLE TO OPERATE THIS PROGRAM ";
6100 [153]"AND MAKE GREAT SOUNDS ON THE COMMODORE 64"
6110 [153]"
6120 PRINT"1. EVERY LOCATION IN THE SID CHIP IS REPRESENTED BY A LOCATION";
6130 PRINT" ON THE SCREEN (A-Y) IN THAT ORDER (A EQUALING 54272)"
6140 PRINT"
6150 [153]"2. THEREFORE YOU ARE ONLY ABLE TO PUT THE NUMBERS 0-255 IN A";
6160 [153]" LOCATION"
6170 [153]"
6180 PRINT"3. TO SEE A LIST OF ALL THE COMMANDS ATANY TIME (WITHOUT ANY";
6190 PRINT" EFFECT ON WHAT YOU ARE DOING) PRESS THE LETTER 'I' ";
6200 PRINT" (FOR INSTRUCTIONS)"
6210 PRINT"
6220 [153]"4. FINALLY TO UNDERSTAND, AND BE ABLE TO PUT THE RIGHT VALUE";
6230 [153]" IN THE APPRORIATELOCATION REFER TO THE COMMODORE 64";
6240 [153]" REFERENCE MANUAL'S SECTION ON SOUND AND MUSIC"
6250 [153]" HIT ANY KEY TO CONTINUE ";
6260 [161] A$
6265 [139] A$[178]"" [167] [137] 6260
6270 [153]"LOAD COMMAND LIST WAIT"
6280 [153]"
6285 PRINT"
6290 [153]" Q -- QUIT (EXIT) PROGRAM"
6300 [153]"
6310 PRINT" R -- RESET ALL VALUES (LOCATIONS)"
6320 PRINT"
6330 [153]" I -- PRINTS THIS LIST"
6340 [153]"
6350 PRINT" C -- CHANGE VALUE OF A SPECIFIC LOCATION"
6360 PRINT"
6370 [153]" F1 -- PLAY VOICE 1"
6380 [153]"
6390 PRINT" F3 -- PLAY VOICE 2"
6400 PRINT"
6410 [153]" F5 -- PLAY VOICE 3"
6420 [153]"
6430 PRINT" F7 -- PLAY VOICE 1,2,3"
6440 PRINT"
6450 [153]" P.S. MASTER VOLUME IS FROM 1-15
6460 PRINT" THE CONTROL REGISTER CONTAINS
6461 [153]" 16,32,64,OR 128 ONLY
6470 PRINT" HIT ANY KEY TO CONTINUE [146]"
6480 GET A$:IF A$="" THEN 6480
6490 RETURN
7000 REM ** ROUTINE FOR ON-LINE INSTRUCTIONS **********************************
7005 GOSUB 6270
7010 GOSUB 100
7020 FOR N=0 TO 25
7030 GOSUB 1000
7040 NEXT N
7050 RETURN
8000 REM ** GET ROUTINE FOR POKE VALUE ****************************************
8010 N$=""
8100 POKE SC+921+O,30
8110 GET A$
8120 POKE SC+921+O,158
8130 IF A$="" THEN 8100
8140 IF A$=CHR$(20) THEN O=0:GOSUB 8200
8170 IF A$=CHR$(13) THEN 8500
8180 IF ASC(A$)>47 AND ASC(A$)<58 THEN GOSUB 8600
8190 GOTO 8110
8200 REM ** GET ROUTINE FOR THE DEL KEY ***************************************
8210 N$=""
82